package com.xd.demo.dto;

import lombok.Data;


/**
 * 通用请求处理参数
 *
 * @author daishun
 * @since 2019/8/26
 */
@Data
public class ReqDto<T> {
    /**
     * 系统来源或者channel
     */

    private String fromSystem;
    /**
     * 对资产方该字段是requestKey
     */

    private String key;
    /**
     * 类型,服务名称
     */

    private String type;
    /**
     * 请求时间戳
     */
    private long timestamp;
    /**
     * 业务参数
     */

    private T data;

    public ReqDto() {
    }



    public ReqDto(T data, String fromSystem) {
        this.data = data;
        this.fromSystem = fromSystem;
    }
    public ReqDto(T data, String fromSystem, String key) {
        this.data = data;
        this.fromSystem = fromSystem;
        this.key = key;
    }
}
